<!DOCTYPE html>
<html>

<head>
    <meta charset="UTF-8">
    <title>栈板管理-精工云MES系统移动端</title>
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
    <link href="/JG/Content/jquery/weui/style/weui.min.css" rel="stylesheet" />
    <link href="/JG/Content/jquery/jquery-weui/css/jquery-weui.min.css" rel="stylesheet" />
    <link href="/JG/Content/jquery/jquery-weui/css/jquery-weui.css" rel="stylesheet" />
    <link href="/JG/Content/css/Global.css" rel="stylesheet" />
    <link rel="stylesheet" href="/JG/Content/css/MobilePalletManagement.css">
    <link href="/JG/Content/jquery/jquery-weui/css/icon.css" rel="stylesheet" />
    <script src="/JG/Content/LocalConfigs.js?v=1"></script>
    <script src="/JG/Content/LocalUserInfo.js"></script>
    <style>
        [v-cloak] {
            display: none;
        }
    </style>
</head>

<body>
    <header class="header">
        <div class="empty">
            <span id="stations"></span>
        </div>
        <div class="weui-flex">
            <div class="weui-flex__item" style="position:absolute;">
                <span style="font-size:16px" class="icon icon-109 f-white"
                    onclick="javascript:location.href='/JG/Home/MobileIndex.html'">返回</span>
            </div>
            <div class="weui-flex__item" style="text-align: center;">栈板管理</div>
        </div>
    </header>
    <div id="MainPage" v-cloak>
        <div class="page">
            <div class="weui-flex tabbar">
                <div class="weui-flex__item " @click="GetProcessingListData">
                    <a class="weui-navbar__item   active" href="javascript:;">
                        待处理列表
                    </a>
                </div>
                <div class="weui-flex__item" @click="GetBindingListData">
                    <a class="weui-navbar__item" href="javascript:;">
                        绑定
                    </a>
                </div>
                <div class="weui-flex__item" @click="GetHistoryListData">
                    <a class="weui-navbar__item" href="javascript:;">
                        历史列表
                    </a>
                </div>
            </div>
            <div class="content">
                <div class="tab1">
                    <div class="weui-flex ser">
                        <div class="search">
                            <input type="text" placeholder="订单号码" class="wordcode input1" v-model="ProcessOrderNumber"
                                autofocus id="WordCode">
                            <input type="text" placeholder="栈板条码号" v-model="ProcessPalletNumber" class="zhancode">
                            <button class="searchbtn" id="processsearch" @click="ProcessingSearch">查询</button>
                        </div>
                    </div>
                    <div class="tabletitle">
                        <div class="tabtitle">
                            <ul style="font-weight: bold;">
                                <li>
                                    序号
                                </li>
                                <li>
                                    订单号码
                                </li>
                                <li>
                                    栈板条码号
                                </li>
                                <li>
                                    箱数
                                </li>
                                <li>
                                </li>
                            </ul>
                        </div>
                        <div class="tablebody" style="overflow: auto;">
                            <ul v-for="(item,index ) in ProcessingListData" :key="index"
                                @click="ProcessingListCheck(item)" :class="{'checkdelect':item.isShow}"
                                style="height: 38px;">
                                <li>{{++index}}</li>
                                <li style="height: -webkit-fill-available;;">{{item.ZBBD_DDHM}}</li>
                                <li style="height: -webkit-fill-available;">{{item.ZBBD_ZBTMH}}</li>
                                <li>{{item.ZBBD_YZSL}}</li>
                                <li style="font-weight: bold; color: #5cb85c;" @click.stop="ProcessingSwitch(item)">>
                                </li>
                            </ul>
                        </div>
                        <div class="tablefoot">
                            <ul class="czbtn">
                                <li></li>
                                <li style="text-align: center;">
                                    <span class="prebtn processpre" :class="{'disabled': ProcessingCurrPage == 1}"
                                        @click="Processingpre">&lt;&nbsp;&nbsp;</span>
                                    <span>{{ProcessingCurrPage}}</span>
                                    <!-- <input type="tel" value="1" v-model="ProcessingCurrPage" class="pageNum2"
                                        maxlength="5"
                                        onkeyup="if(this.value.length==1){this.value=this.value.replace(/[^1-9]/g,'')}else{this.value=this.value.replace(/\D/g,'')}"
                                        onafterpaste="if(this.value.length==1){this.value=this.value.replace(/[^1-9]/g,'')}else{this.value=this.value.replace(/\D/g,'')}" /> -->
                                    <span>/</span>
                                    <span>{{Math.ceil(ProcessingTotalCount/ProcessingPageSize)}}</span>
                                    <span class="nextbtn processnext"
                                        :class="{'disabled': ProcessingCurrPage == ProcessingtotalPage}"
                                        @click="Processingnext">&nbsp;&nbsp;&gt;</span>
                                </li>
                                <li><button @click="ProcessingListDelect">删除</button></li>
                            </ul>
                        </div>
                    </div>
                </div>
                <div class="tab2 ">
                    <div class="nav">
                        <div class="weui-flex ser bortom" style="padding: .3rem;">
                            <div class="navitem">
                                <span style="width: 80px;display: inline-block;">扫码：<span
                                        style="color:red">*</span></span>
                                <input type="text" id="ScanCode" placeholder="扫码或录入" class="input2"
                                    style="outline-style: none;" v-model="BindingList.FaceScanPayment" autofocus>
                            </div>
                        </div>
                        <div class="weui-flex ser bortom" style="padding: .3rem;">
                            <div class="navitem">
                                <span style="width: 80px;display: inline-block;">栈板条码：</span>
                                <input type="text" style="outline-style: none;" :value="BindingList.PalletCode" readonly
                                    autofocus>
                            </div>
                        </div>
                        <div class="weui-flex ser" style="padding: .3rem;">
                            <div class="navitem naitem">
                                <span style="width: 80px;display: inline-block;">外箱列表</span>
                                <span>应装数量：{{WXNum}}箱</span>
                            </div>
                        </div>
                    </div>
                    <div class="tabletitle2">
                        <div class="tabtitle2 tab">
                            <ul style="font-weight: bold;">
                                <li>
                                    序号
                                </li>
                                <li>
                                    外箱条码号
                                </li>
                                <li>
                                    已扫数量：<span>{{CartonBarcode.length}}</span> 箱&nbsp;
                                </li>
                            </ul>
                        </div>
                        <div class="tablebody2  tab" style="overflow: auto;">
                            <ul class="" v-for="(item,index) in CartonBarcode" :key="index">
                                <li>{{BindingNum+index}}</li>
                                <li>{{item.ZBBDZB_WXTMH}}</li>
                                <li><img src="/JG/Content/images/bad_img.png" alt=""
                                        @click="BindingDelectOne(index,item)">
                                </li>
                            </ul>
                        </div>
                        <div class="tablefoot2">
                            <ul class="lsbtn">
                                <li style="text-align: left;"><button class="save" @click="SaveData">保存</button></li>
                                <li class="check">
                                    <label for="auto"> <input id="auto" type="checkbox" @click="IsChecked($event)">
                                        <span style="vertical-align: middle;">自动保存</span></label>
                                </li>
                                <li><button class="delete" @click="BindingDelectAll">删除</button></li>
                            </ul>
                        </div>
                    </div>
                </div>
                <div class="tab3">
                    <div class="weui-flex ser">
                        <div class="search">
                            <input type="text" id="hisorder" placeholder="订单号码" class="wordcode input3"
                                v-model="HistoryOrderNumber" autofocus>
                            <input type="text" placeholder="栈板条码号" v-model="HistoryPalletNumber" class="zhancode">
                            <button class="searchbtn" @click="HistorySearch">查询</button>
                        </div>
                    </div>
                    <div class="tabletitle">
                        <div class="tabtitle">
                            <ul style="font-weight: bold;">
                                <li>
                                    序号
                                </li>
                                <li>
                                    订单号码
                                </li>
                                <li>
                                    栈板条码号
                                </li>
                                <li>
                                    箱数
                                </li>
                                <li>

                                </li>
                            </ul>
                        </div>
                        <div class="tablebody3" style="overflow: auto;">
                            <ul class="" v-for="(item,index ) in HistoryListData" :key="index"
                                @click="HistoryListCheck(item)" :class="{'checkdelect':item.isShow}">
                                <li>{{++index}}</li>
                                <li>{{item.ZBBD_DDHM}}</li>
                                <li>{{item.ZBBD_ZBTMH}}</li>
                                <li>{{item.ZBBD_YZSL}}</li>
                                <li style="font-weight: bold; color: #5cb85c;" @click.stop="HistorySwitch(item)">></li>
                            </ul>
                        </div>
                        <div class="tablefoot">
                            <ul class="lsbtn">
                                <li></li>
                                <li style="text-align: center;">
                                    <span class="prebtn historypre" :class="{'disabled': HistoryCurrPage == 1}"
                                        @click="Historypre">&lt;&nbsp;&nbsp;</span>
                                    <span>{{HistoryCurrPage}}</span>
                                    <!-- <input type="tel" value="1" class="pageNum" maxlength="5"
                                        onkeyup="if(this.value.length==1){this.value=this.value.replace(/[^1-9]/g,'1')}else{this.value=this.value.replace(/\D/g,'1')}"
                                        onafterpaste="if(this.value.length==1){this.value=this.value.replace(/[^1-9]/g,'1')}else{this.value=this.value.replace(/\D/g,'1')}" /> -->
                                    <span>/</span>
                                    <span>{{Math.ceil(HistoryTotalCount/HistoryPageSize)}}</span>
                                    <span class="nextbtn historynext"
                                        :class="{'disabled': HistoryCurrPage == HistorytotalPage }"
                                        @click="Historynext">&nbsp;&nbsp;&gt;</span>
                                </li>
                                <li><button class="delete" @click="HistoryListDelect">删除</button></li>
                            </ul>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    </div>
    <script src="/JG/Content/jquery.min.js"></script>
    <script src="/JG/Content/vue-v2.34.js"></script>
    <script src="/JG/Content/jquery/jquery-weui/js/jquery-weui.min.js"></script>
    <script src="/JG/Content/Utils.js?v=1"></script>
    <script src="/JG/Content/Common.js"></script>
    <script src="/JG/Content/AudioUtils.js"></script>
    <script type='text/javascript'>
        $(document).ready(function () {// ready 事件
            $(".tabbar>div>a").each(function (index) {//便利对象
                $(this).click(function () {//点击触发事件
                    $(".tabbar>div>a").removeClass("active");//删除当前元素的样式
                    $(".tabbar>div>a").eq(index).addClass("active");//添加当前元素的样式
                    $('.content>div').hide();
                    $('.content>div').eq(index).show();
                });
            });
        });
        window.onload = function () {
            var BodyWidth = $(window).width();
            var BodyHeight = $(window).height();
            var TableBodyHeight = (BodyHeight / 2) - 23;
            var TableBodyHeight2 = (BodyHeight / 3) - 8;
            $(".tablebody,.tablebody3").height(TableBodyHeight)
            $(".tablebody2").height(TableBodyHeight2)
        }
    </script>
    <script type="text/javascript">
        var vmPage = new Vue({
            el: "#MainPage",
            data: {
                ProcessingListData: [],//待处理列表数据集合          
                selectedProcessingList: [],//待处理列表选中储存            
                ProcessOrderNumber: "", //待处理列表订单号码
                ProcessPalletNumber: "",//待处理列表栈板条码
                ProcessingPageSize: 10,//待处理列表每页显示条数
                ProcessingTotalCount: 0,//待处理列表初始条数
                ProcessingCurrPage: 1,//待处理列表当前页数
                BindingList: {           //绑定数据
                    FaceScanPayment: "",//扫码
                    PalletCode: "",//栈板码
                    WordCode: ""//订单号码
                },
                BindingListData: [],//绑定列表数据集合                                
                BindingNum: 1, //绑定序号初始值
                CartonBarcode: [],//外箱条码集合
                SaveReturnStatus: false,//绑定列表保存返回状态
                BindingID: "",//绑定的ID
                HistoryListData: [],//历史列表数据集合          
                selectedHistoryList: [],//历史列表选中储存
                HistoryOrderNumber: "", //历史列表订单号码
                HistoryPalletNumber: "",//历史列表栈板条码        
                HistoryPageSize: 10,//历史列表每页显示条数
                HistoryCurrPage: 1,//历史列表初始页码
                HistoryTotalCount: 0,//历史列表初始条数
                timeout: null,
                tmyygzDynaBean: [], //条码应用规则
                WXBarCodeApplicationRules: "",//外箱条码类型
                WXNum: "",//外箱应装数量
                ZBBarCodeApplicationRules: "",//栈板条码类型
                SwitchStatusData: false,//切换页面判断是否有数据
                modalFormData: "",//自动保存监听          
                SelectStatus: false,
                BindingDataIsChang: false,//绑定页面数据改变状态
            },
            computed: {
                ProcessingtotalPage: function () {
                    var currSelf = this;
                    return Math.ceil(currSelf.ProcessingTotalCount / currSelf.ProcessingPageSize);
                },
                HistorytotalPage: function () {
                    var currSelf = this;
                    return Math.ceil(currSelf.HistoryTotalCount / currSelf.HistoryPageSize);
                }
            },
            mounted: function () {
                var currSelf = this;
                // $("#ScanCode").bind("keypress", currSelf.SearchScanCode)
                $("#ScanCode").bind("keypress", currSelf.Entenr)
                $("#ScanCode").focus();

                //初始化待处理列表
                $.showLoading();
                $.ajax({
                    type: "post",
                    url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!getZBTMSj.action",
                    data: {
                        mac: LocalUserInfo.GetUserInfo().Mac,
                        userCode: LocalUserInfo.GetUserInfo().UserCode,
                        isComplete: '0',
                        ddhm: currSelf.ProcessOrderNumber,
                        barCode: currSelf.ProcessPalletNumber,
                        PageSize: currSelf.ProcessingPageSize,
                        CurrPage: currSelf.ProcessingCurrPage,
                    },
                    dataType: "json",
                    success: function (result) {
                        var retData = ReturnData(result);
                        if (retData.IsSuccess) {
                            currSelf.ProcessingListData = retData.Data;
                            for (var index in currSelf.ProcessingListData) {
                                currSelf.ProcessingListData[index].isShow = false
                            }
                            for (var key in currSelf.ProcessingListData) {
                                currSelf.ProcessingTotalCount = retData.TotalCount;
                                return false;//返回false，不为空对象
                            }
                            currSelf.ProcessingTotalCount = 1;

                            $.toptip("未找到相关信息", "error");
                            //AudioUtils.Play(AudioUtils.NotFind);
                            return true;//返回true，为空对象
                        }
                    },
                    error: function (xhr, status, errorThrow) {
                        console.error(status);
                        $.alert("获取信息失败!");
                        AudioUtils.Play(AudioUtils.ErrorMessage);
                    },
                    complete: function () {
                        $.hideLoading();
                    },
                })
            },
            methods: {
                //待处理列表数据获取
                GetProcessingListData: function () {
                    var currSelf = this;
                    $("#WordCode").focus();
                    currSelf.ProcessingCurrPage = 1;
                    currSelf.ProcessOrderNumber = "";
                    currSelf.ProcessPalletNumber = "";

                    if (currSelf.BindingDataIsChang) {
                        $.modal({
                            title: "操作提示",
                            text: "离开绑定数据会丢失，请先保存！",
                            buttons: [
                                {
                                    text: "否", onClick: function () {
                                        $(".tabbar>div>a").removeClass("active");//删除当前元素的样式
                                        $(".tabbar>div>a").eq(0).addClass("active");//添加当前元素的样式
                                        $('.content>div').hide();
                                        $('.content>div').eq(0).show();
                                        currSelf.CartonBarcode = [];
                                        currSelf.BindingList.WordCode = "";
                                        currSelf.BindingDataIsChang = false;
                                        currSelf.tmyygzDynaBean = [];
                                        currSelf.BindingID = "";
                                    }
                                },
                                {
                                    text: "是", onClick: function () {
                                        $(".tabbar>div>a").removeClass("active");//删除当前元素的样式
                                        $(".tabbar>div>a").eq(1).addClass("active");//添加当前元素的样式
                                        $('.content>div').hide();
                                        $('.content>div').eq(1).show();
                                    }
                                },
                            ]
                        });
                    } else {
                        currSelf.CartonBarcode = [];
                        currSelf.BindingList.WordCode = "";
                        currSelf.tmyygzDynaBean = [];
                    }
                    $.showLoading();
                    $.ajax({
                        type: "post",
                        url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!getZBTMSj.action",
                        data: {
                            mac: LocalUserInfo.GetUserInfo().Mac,
                            userCode: LocalUserInfo.GetUserInfo().UserCode,
                            isComplete: '0',
                            ddhm: currSelf.ProcessOrderNumber,
                            barCode: currSelf.ProcessPalletNumber,
                            PageSize: currSelf.ProcessingPageSize,
                            CurrPage: currSelf.ProcessingCurrPage,
                        },
                        dataType: "json",
                        success: function (result) {
                            var retData = ReturnData(result);
                            if (retData.IsSuccess) {
                                currSelf.ProcessingListData = retData.Data;
                                for (var key in currSelf.ProcessingListData) {
                                    currSelf.ProcessingTotalCount = retData.TotalCount;
                                    return false;//返回false，不为空对象
                                }
                                currSelf.ProcessingTotalCount = 1;
                                $.toptip("未找到相关信息", "error");
                                return true;//返回true，为空对象
                            }
                        },
                        error: function (xhr, status, errorThrow) {
                            console.error(status);
                            $.alert("获取信息失败!");
                            AudioUtils.Play(AudioUtils.ErrorMessage);
                        },
                        complete: function () {
                            $.hideLoading();
                        },
                    })
                },
                //待处理列表的选中/取消选中
                ProcessingListCheck: function (item) {
                    var currSelf = this;
                    if (!item.isShow) {
                        item.isShow = true;
                        currSelf.selectedProcessingList.push(item.GMES_PB_ZBBD_ID)
                    } else {
                        item.isShow = false;
                        var index = currSelf.selectedProcessingList.indexOf(item.GMES_PB_ZBBD_ID);
                        if (index > -1) {
                            currSelf.selectedProcessingList.splice(index, 1);
                        }
                    }
                    currSelf.$forceUpdate();//强制刷新渲染
                },
                //待处理列表的批量删除
                ProcessingListDelect: function () {
                    var currSelf = this;
                    if (currSelf.selectedProcessingList.length > 0) {
                        $.confirm(" 确定要删除选中数据？", "操作提示",
                            function () {
                                //点击确认后的回调函数
                                for (var i = 0; i < currSelf.ProcessingListData.length; i++) {
                                    if (currSelf.ProcessingListData[i].isShow) {
                                        currSelf.ProcessingListData.splice(i, 1)
                                        i--
                                    }
                                }
                                var ids = currSelf.selectedProcessingList.join(',');
                                $.showLoading();
                                $.ajax({
                                    type: "post",
                                    url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!doDeleteZBBD.action",
                                    data: {
                                        mac: LocalUserInfo.GetUserInfo().Mac,
                                        userCode: LocalUserInfo.GetUserInfo().UserCode,
                                        zbId: ids,
                                        zbzbId: ""
                                    },
                                    dataType: "json",
                                    success: function (result) {
                                        var retData = ReturnData(result);
                                        if (retData.IsSuccess) {
                                        }
                                        currSelf.selectedProcessingList = [];
                                    },
                                    error: function (xhr, status, errorThrow) {
                                        console.error(status);
                                        $.alert("获取信息失败!");
                                        AudioUtils.Play(AudioUtils.ErrorMessage);
                                    },
                                    complete: function () {
                                        $.hideLoading();
                                    },
                                })
                            }
                        );
                    } else {
                        $.toptip("请选择您要删除的数据", "warning");
                        AudioUtils.Play(AudioUtils.SelectDeleted);

                    }
                },
                //待处理列表编辑信息切换到绑定列表
                ProcessingSwitch: function (item) {
                    var currSelf = this;
                    $(".tabbar>div>a").removeClass("active");//删除当前元素的样式
                    $(".tabbar>div>a").eq(1).addClass("active");//添加当前元素的样式
                    $('.content>div').hide();
                    $('.content>div').eq(1).show();
                    currSelf.BindingList.PalletCode = item.ZBBD_ZBTMH;
                    currSelf.BindingID = item.GMES_PB_ZBBD_ID;
                    currSelf.WXNum = item.ZBBD_NXSL;
                    currSelf.BindingList.WordCode = item.ZBBD_DDHM;
                    if (item.detail && item.detail.length > 0) {
                        currSelf.CartonBarcode = item.detail;
                    }
                },
                //待处理列表查询按钮
                ProcessingListSearch: function () {
                    var currSelf = this;
                    $.showLoading();
                    $.ajax({
                        type: "post",
                        url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!getZBTMSj.action",
                        data: {
                            mac: LocalUserInfo.GetUserInfo().Mac,
                            userCode: LocalUserInfo.GetUserInfo().UserCode,
                            isComplete: '0',
                            ddhm: currSelf.ProcessOrderNumber,
                            barCode: currSelf.ProcessPalletNumber,
                            PageSize: currSelf.ProcessingPageSize,
                            CurrPage: currSelf.ProcessingCurrPage,
                        },
                        dataType: "json",
                        success: function (result) {
                            var retData = ReturnData(result);
                            if (retData.IsSuccess) {

                                currSelf.ProcessingListData = retData.Data;
                                for (var key in currSelf.ProcessingListData) {
                                    currSelf.ProcessingTotalCount = retData.TotalCount;
                                    currSelf.ProcessOrderNumber = "";
                                    currSelf.ProcessPalletNumber = "";
                                    return false;//返回false，不为空对象
                                }
                                currSelf.ProcessingTotalCount = 1;
                                currSelf.ProcessOrderNumber = "";
                                currSelf.ProcessPalletNumber = "";
                                $.toptip("未找到相关信息", "error");
                                return true;//返回true，为空对象
                            }
                        },
                        error: function (xhr, status, errorThrow) {
                            console.error(status);
                            $.alert("获取信息失败!");
                            AudioUtils.Play(AudioUtils.ErrorMessage);
                        },
                        complete: function () {
                            $.hideLoading();
                        },
                    })
                },
                //待处理查询
                ProcessingSearch: function () {
                    var currSelf = this;
                    currSelf.ProcessingCurrPage = 1;
                    currSelf.ProcessingListSearch();
                },
                //待处理列表上一页切换
                Processingpre: function () {
                    var currSelf = this;
                    if (currSelf.ProcessingCurrPage > 1) {
                        currSelf.ProcessingCurrPage--;
                        currSelf.ProcessingListSearch()
                    }
                },
                //待处理列表下一页切换
                Processingnext: function () {
                    var currSelf = this;
                    if (currSelf.ProcessingCurrPage < Math.ceil(currSelf.ProcessingTotalCount / currSelf.ProcessingPageSize)) {
                        currSelf.ProcessingCurrPage++;
                        currSelf.ProcessingListSearch()
                    }
                },

                //回车
                Entenr: function () {
                    var currSelf = this;
                    if (event.which == 13) {
                        currSelf.SearchScanCode();
                        //判断数据有没改变
                        if (currSelf.BindingDataIsChang && currSelf.SelectStatus) {
                            currSelf.AllSaveData(0);
                        }
                    }
                },
                //绑定列表的扫码查询
                SearchScanCode: function () {
                    var currSelf = this;
                    if (currSelf.BindingList.FaceScanPayment) {
                        var BindingListBarCode = currSelf.BindingList.FaceScanPayment.trim();
                        currSelf.BindingList.FaceScanPayment = "";
                        if (currSelf.tmyygzDynaBean.length > 0) {
                            if (Utils.IsTest(currSelf.WXBarCodeApplicationRules, BindingListBarCode)) { //外箱条码类型   
                                currSelf.WXverification(BindingListBarCode);
                            } else if (Utils.IsTest(currSelf.ZBBarCodeApplicationRules, BindingListBarCode)) {//栈板条码类型  
                                currSelf.ZBverification(BindingListBarCode)
                            } else {
                                $.toptip("未知的条码号，请检查！", "error");
                                AudioUtils.Play(AudioUtils.AlarmSound);
                                currSelf.BindingDataIsChang = false;
                                return;
                            }
                        } else {
                            $.showLoading();
                            $.ajax({
                                type: "post",
                                async: false,
                                url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!getInfoByBarCode.action",
                                data: {
                                    userCode: LocalUserInfo.GetUserInfo().UserCode,
                                    barCode: BindingListBarCode,
                                },
                                dataType: "json",
                                success: function (result) {
                                    var retData = ReturnData(result);
                                    // var retData = result;
                                    if (retData.IsSuccess) {
                                        currSelf.tmyygzDynaBean = retData.Data.tmyygzDynaBean;
                                        for (var j = 0; j < currSelf.tmyygzDynaBean.length; j++) {
                                            if (currSelf.tmyygzDynaBean[j].CPTMYYGG_TMLX_CODE == "TMLX04" && (retData.Data.TmLx == "TMWX" || retData.Data.TmLx == "TMCP")) { //外箱条码类型                                             
                                                currSelf.WXBarCodeApplicationRules = currSelf.tmyygzDynaBean[j].CPTMYYGG_TMYZGZ;
                                                if (!currSelf.BindingList.WordCode) {
                                                    currSelf.BindingList.WordCode = retData.Data.tmScDynaBean.GDCPTM_DDHM;
                                                }
                                                for (var y = 0; y < currSelf.tmyygzDynaBean.length; y++) {
                                                    if (currSelf.tmyygzDynaBean[y].CPTMYYGG_TMLX_CODE == "TMLX05") {
                                                        currSelf.WXNum = currSelf.tmyygzDynaBean[y].CPTMYYGG_MTMSL;
                                                        currSelf.ZBBarCodeApplicationRules = currSelf.tmyygzDynaBean[y].CPTMYYGG_TMYZGZ;
                                                    }
                                                }
                                                currSelf.WXverification(BindingListBarCode);
                                            } else if (currSelf.tmyygzDynaBean[j].CPTMYYGG_TMLX_CODE == "TMLX05" && retData.Data.TmLx == "TMZB") {//栈板条码类型

                                                currSelf.ZBBarCodeApplicationRules = currSelf.tmyygzDynaBean[j].CPTMYYGG_TMYZGZ;
                                                if (!currSelf.BindingList.WordCode) {
                                                    currSelf.BindingList.WordCode = retData.Data.tmScDynaBean.GDCPTM_DDHM;
                                                }
                                                currSelf.WXNum = currSelf.tmyygzDynaBean[j].CPTMYYGG_MTMSL;
                                                for (var x = 0; x < currSelf.tmyygzDynaBean.length; x++) {
                                                    if (currSelf.tmyygzDynaBean[x].CPTMYYGG_TMLX_CODE == "TMLX04") {
                                                        currSelf.WXBarCodeApplicationRules = currSelf.tmyygzDynaBean[x].CPTMYYGG_TMYZGZ;
                                                    }
                                                }
                                                currSelf.ZBverification(BindingListBarCode)
                                            } else if (currSelf.tmyygzDynaBean[j].CPTMYYGG_TMLX_CODE == "TMLX09" && retData.Data.TmLx == "TMHGB") {
                                                if (!currSelf.BindingList.WordCode) {
                                                    currSelf.BindingList.WordCode = retData.Data.tmScDynaBean.GDCPTM_DDHM;
                                                }
                                                for (var a = 0; a < currSelf.tmyygzDynaBean.length; a++) {
                                                    if (currSelf.tmyygzDynaBean[a].CPTMYYGG_TMLX_CODE == "TMLX04") {
                                                        currSelf.WXBarCodeApplicationRules = currSelf.tmyygzDynaBean[a].CPTMYYGG_TMYZGZ;
                                                    }
                                                }
                                                for (var b = 0; b < currSelf.tmyygzDynaBean.length; b++) {
                                                    if (currSelf.tmyygzDynaBean[b].CPTMYYGG_TMLX_CODE == "TMLX05") {
                                                        currSelf.WXNum = currSelf.tmyygzDynaBean[b].CPTMYYGG_MTMSL;
                                                        currSelf.ZBBarCodeApplicationRules = currSelf.tmyygzDynaBean[b].CPTMYYGG_TMYZGZ;
                                                    }
                                                }
                                                $.toptip("未知的条码号，请检查！", "error");
                                                AudioUtils.Play(AudioUtils.AlarmSound);
                                                currSelf.BindingDataIsChang = false;
                                                return;
                                            }
                                        }
                                    }else{
                                    	AudioUtils.Play(AudioUtils.AlarmSound);
                                    }

                                },
                                error: function (xhr, status, errorThrow) {
                                    console.error(status);
                                    $.alert("获取信息失败!");
                                    AudioUtils.Play(AudioUtils.ErrorMessage);
                                },
                                complete: function () {
                                    $.hideLoading();
                                },
                            })
                        }
                    } else {
                        $.toptip("请扫码或录入", "warning");
                        AudioUtils.Play(AudioUtils.SweepCodeEntry);
                    }
                },
                //栈板条码更换               
                ZBverification: function (BindingListBarCode) {
                    var currSelf = this;
                    // currSelf.BindingList.PalletCode = BindingListBarCode;

                    if (currSelf.BindingList.PalletCode) {
                        if (currSelf.BindingList.PalletCode != BindingListBarCode) {
                            $.modal({
                                title: "操作提示",
                                text: "栈板条码是否要更换！",
                                buttons: [
                                    {
                                        text: "否", onClick: function () {
                                        }
                                    },
                                    {
                                        text: "是", onClick: function () {
                                            currSelf.BindingList.PalletCode = BindingListBarCode;
                                            currSelf.BindingDataIsChang = true;
                                            currSelf.ZBBarCodeChang();
                                            //判断数据有没改变
                                            if (currSelf.BindingDataIsChang && currSelf.SelectStatus) {
                                                currSelf.AllSaveData(0);
                                            }
                                        }
                                    },
                                ]
                            });
                        } else {
                            currSelf.BindingList.PalletCode = BindingListBarCode;
                            currSelf.BindingDataIsChang = true;
                            currSelf.ZBBarCodeChang();
                        }
                    } else {
                        currSelf.BindingList.PalletCode = BindingListBarCode;
                        currSelf.BindingDataIsChang = true;
                        currSelf.ZBBarCodeChang();
                    }
                },
                //栈板条码验证方法封装
                ZBBarCodeChang: function () {
                    var currSelf = this;
                    $.showLoading();
                    $.ajax({
                        type: "post",
                        async: false,
                        url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!getZBTMSj.action",
                        data: {
                            mac: LocalUserInfo.GetUserInfo().Mac,
                            userCode: LocalUserInfo.GetUserInfo().UserCode,
                            isComplete: "",
                            ddhm: currSelf.BindingList.WordCode,
                            barCode: currSelf.BindingList.PalletCode,
                            PageSize: "",
                            CurrPage: "",
                        },
                        dataType: "json",
                        success: function (result) {
                            var retData = ReturnData(result);
                            if (retData.IsSuccess) {
                                if (retData.Data != null) {
                                    currSelf.BindingID = retData.Data[0].GMES_PB_ZBBD_ID;
                                }
                                for (var key in retData.Data) {
                                    if (retData.Data[key].detail && retData.Data[key].detail.length > 0) {
                                        currSelf.CartonBarcode = retData.Data[key].detail;
                                    }
                                    return false;//返回false，不为空对象
                                }
                                return true;//返回true，为空对象
                            }
                        },
                        error: function (xhr, status, errorThrow) {
                            console.error(status);
                            $.alert("获取信息失败!");
                            AudioUtils.Play(AudioUtils.ErrorMessage);
                        },
                        complete: function () {
                            $.hideLoading();
                        },
                    })
                    return;
                },

                //外箱条码验证方法封装
                WXverification: function (BindingListBarCode) {
                    var currSelf = this;
                    if (currSelf.WXNum) {
                        if (currSelf.CartonBarcode.length >= currSelf.WXNum) {//外箱码最大WXNum箱
                            $.toptip("外箱条码已达到" + currSelf.WXNum + "箱", "warning");
                            AudioUtils.Play(AudioUtils.Cartons);
                            // currSelf.BindingDataIsChang = true;
                        } else {//小于WXNum箱
                            if (currSelf.CartonBarcode.length > 0) {//校验外箱码唯一性
                                var isBarCode;
                                for (var i = 0; i < currSelf.CartonBarcode.length; i++) {
                                    isBarCode = currSelf.CartonBarcode[i].ZBBDZB_WXTMH.indexOf(BindingListBarCode);
                                    if (isBarCode > -1) {
                                        $.toptip("此外箱条码已存在", "warning");
                                        AudioUtils.Play(AudioUtils.BarcodeExists);
                                        return;
                                    }
                                }
                                currSelf.CartonBarcode.push({
                                    ZBBDZB_WXTMH: BindingListBarCode,
                                })
                                currSelf.BindingDataIsChang = true;
                            } else {//外箱码长度为0时，不做校验
                                currSelf.CartonBarcode.push({
                                    ZBBDZB_WXTMH: BindingListBarCode,
                                })
                                currSelf.BindingDataIsChang = true;
                            }
                        }
                    } else {
                        $.toptip("未知的条码号，请检查！", "error");
                        AudioUtils.Play(AudioUtils.AlarmSound);
                        currSelf.BindingDataIsChang = false;
                    }
                    return;
                },

                //保存绑定主子表数据
                AllSaveData: function (IsFinish) {
                    var currSelf = this;
                    //保存绑定主表
                    var jsonStr = JSON.stringify({
                        "ZBBD_ZBTMH": currSelf.BindingList.PalletCode,//栈板条码号
                        "ZBBD_NXSL": currSelf.WXNum,//内箱数量
                        "ZBBD_DDHM": currSelf.BindingList.WordCode,//订单号码
                        "ZBBD_NO_CODE": IsFinish,//是否完成0/1
                        "GMES_PB_ZBBD_ID": currSelf.BindingID,
                        "ZBBD_YZSL": currSelf.CartonBarcode.length,
                    });
                    //保存绑定子表
                    var jsonStrDetail = [];
                    for (var i in currSelf.CartonBarcode) {
                        var element = currSelf.CartonBarcode[i];
                        jsonStrDetail.push({
                            "ZBBDZB_WXTMH": element.ZBBDZB_WXTMH.trim(),//外箱条码号
                            "ZBBDZB_ZBTMH": currSelf.BindingList.PalletCode,//栈板条码号
                            "GMES_PB_ZBBDZB_ID": element.GMES_PB_ZBBDZB_ID,
                        })
                    }
                    $.showLoading();
                    $.ajax({
                        type: "post",
                        async: false,
                        url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!doSaveZBTM.action",
                        data: {
                            mac: LocalUserInfo.GetUserInfo().Mac,
                            userCode: LocalUserInfo.GetUserInfo().UserCode,
                            jsonStr: jsonStr,
                            jsonStrDetail: JSON.stringify(jsonStrDetail),
                        },
                        dataType: "json",
                        success: function (result) {
                            //var retData = ReturnData(result);
                            var retData = result;
                            if (retData.IsSuccess) {
                                if (retData.Data || retData.Data == null) {

                                    if (retData.message == "" || retData.message == null || retData.message == undefined) {
                                        if (currSelf.BindingList.PalletCode && currSelf.WXNum == currSelf.CartonBarcode.length) {
                                            currSelf.CartonBarcode = [];
                                            currSelf.BindingList.PalletCode = "";
                                            //currSelf.WXNum = "";
                                            currSelf.BindingID = "";
                                        } else {
                                            if (retData.Data != null) {
                                                currSelf.BindingID = retData.Data.GMES_PB_ZBBD_ID;
                                                if (retData.Data.detail && retData.Data.detail.length > 0) {
                                                    currSelf.CartonBarcode = retData.Data.detail;
                                                }
                                            }
                                        }
                                        $.toptip("保存成功", "success");
                                        AudioUtils.Play(AudioUtils.SaveSuccess);
                                        currSelf.BindingDataIsChang = false;
                                    } else {
                                        if (retData.Data != null) {
                                            currSelf.BindingID = retData.Data.GMES_PB_ZBBD_ID;
                                            if (retData.Data.detail) {
                                                currSelf.CartonBarcode = retData.Data.detail;
                                            }
                                        }
                                        $.toptip(retData.message, "error");
                                        AudioUtils.Play(AudioUtils.ErrorMessage);
                                    }
                                    currSelf.ProcessingListData = retData.Data;
                                    // if (retData.Data != null) {
                                    //     currSelf.BindingID = retData.Data.GMES_PB_ZBBD_ID;
                                    // }
                                }
                            } else {
                                $.toptip(retData.message, "error");
                                AudioUtils.Play(AudioUtils.ErrorMessage);
                            }
                        },
                        error: function (xhr, status, errorThrow) {
                            console.error(status);
                            $.alert("获取信息失败!");
                            AudioUtils.Play(AudioUtils.ErrorMessage);
                        },
                        complete: function () {
                            $.hideLoading();
                        },
                    })
                },
                //保存绑定主子表数据
                SaveData: function () {
                    var currSelf = this;
                    if (currSelf.BindingList.PalletCode || currSelf.CartonBarcode.length > 0) {
                        $.modal({
                            title: "操作提示",
                            text: "数据保存类型？",
                            buttons: [
                                {
                                    text: "保存", onClick: function () {
                                        currSelf.AllSaveData(0);
                                    }
                                },
                                {
                                    text: "尾数保存", onClick: function () {
                                        if (!currSelf.BindingList.PalletCode) {
                                            $.toptip("栈板条码为空，不能进行尾数保存", "warning");
                                            AudioUtils.Play(AudioUtils.PalletBarcodeEmpty);
                                        } else if (currSelf.CartonBarcode.length == 0) {
                                            $.toptip("外箱条码为空，不能进行尾数保存", "warning");
                                            AudioUtils.Play(AudioUtils.OuterBarcodeEmpty);
                                        } else {
                                            currSelf.AllSaveData(1);
                                        }
                                    }
                                },
                                { text: "取消", className: "default", onClick: function () { } },
                            ]
                        });
                    }
                },
                //是否选中自动保存按钮
                IsChecked: function (e) {
                    var currSelf = this;
                    if (e.target.checked === true) {
                        currSelf.SelectStatus = e.target.checked;
                    } else if (e.target.checked === false) {
                        currSelf.SelectStatus = e.target.checked;
                    }

                },
                //绑定列表的单个删除
                BindingDelectOne: function (index, item) {
                    var currSelf = this;
                    var wxzjID = item.GMES_PB_ZBBDZB_ID;
                    currSelf.CartonBarcode.splice(index, 1)
                    if (wxzjID) {
                        $.showLoading();
                        $.ajax({
                            type: "post",
                            url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!doDeleteZBBD.action",
                            data: {
                                mac: LocalUserInfo.GetUserInfo().Mac,
                                userCode: LocalUserInfo.GetUserInfo().UserCode,
                                zbId: "",
                                zbzbId: wxzjID,
                            },
                            dataType: "json",
                            success: function (result) {
                                var retData = ReturnData(result);
                                if (retData.IsSuccess) {
                                }
                                currSelf.selectedHistoryList = [];
                            },
                            error: function (xhr, status, errorThrow) {
                                console.error(status);
                                $.alert("获取信息失败!");
                                AudioUtils.Play(AudioUtils.ErrorMessage);
                            },
                            complete: function () {
                                $.hideLoading();
                            },
                        })
                    }
                },
                //绑定列表的全部删除
                BindingDelectAll: function () {
                    var currSelf = this;
                    if (currSelf.CartonBarcode.length > 0) {
                        $.confirm(" 确定要删除全部数据？", "操作提示",
                            function () {
                                //点击确认后的回调函数
                                var ids = [];
                                $.each(currSelf.CartonBarcode, function (index, item) {
                                    ids.push(item.GMES_PB_ZBBDZB_ID);
                                });
                                ids = ids.join(',');
                                $.showLoading();
                                $.ajax({
                                    type: "post",
                                    url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!doDeleteZBBD.action",
                                    data: {
                                        mac: LocalUserInfo.GetUserInfo().Mac,
                                        userCode: LocalUserInfo.GetUserInfo().UserCode,
                                        zbId: "",
                                        zbzbId: ids,
                                    },
                                    dataType: "json",
                                    success: function (result) {
                                        var retData = ReturnData(result);
                                        if (retData.IsSuccess) {
                                        }
                                        currSelf.CartonBarcode.splice(0);
                                    },
                                    error: function (xhr, status, errorThrow) {
                                        console.error(status);
                                        $.alert("获取信息失败!");
                                        AudioUtils.Play(AudioUtils.ErrorMessage);
                                    },
                                    complete: function () {
                                        $.hideLoading();
                                    },
                                })
                            }
                        );
                    }
                },
                //切换到绑定页面清空数据
                GetBindingListData: function () {
                    var currSelf = this;
                    $("#ScanCode").focus();
                    $(".tabbar>div>a").removeClass("active");//删除当前元素的样式
                    $(".tabbar>div>a").eq(1).addClass("active");//添加当前元素的样式
                    $('.content>div').hide();
                    $('.content>div').eq(1).show();
                    //currSelf.BindingList.FaceScanPayment = "";
                    if (currSelf.CartonBarcode.length == 0) {
                        currSelf.CartonBarcode = [];
                        currSelf.BindingList.PalletCode = "";
                        currSelf.WXNum = "";
                        currSelf.BindingID = "";
                    }
                },
                //历史列表的选中/取消选中
                HistoryListCheck: function (item) {
                    var currSelf = this;
                    if (!item.isShow) {
                        item.isShow = true;
                        currSelf.selectedHistoryList.push(item.GMES_PB_ZBBD_ID)
                    } else {
                        item.isShow = false;
                        var index = currSelf.selectedHistoryList.indexOf(item.GMES_PB_ZBBD_ID);
                        if (index > -1) {
                            currSelf.selectedHistoryList.splice(index, 1);
                        }
                    }
                    currSelf.$forceUpdate();//强制刷新渲染
                },
                //历史列表的批量删除
                HistoryListDelect: function () {
                    var currSelf = this;
                    if (currSelf.selectedHistoryList.length > 0) {
                        $.confirm(" 确定要删除选中数据？", "操作提示",
                            function () {
                                //点击确认后的回调函数
                                for (var i = 0; i < currSelf.HistoryListData.length; i++) {
                                    if (currSelf.HistoryListData[i].isShow) {
                                        currSelf.HistoryListData.splice(i, 1)
                                        i--
                                    }
                                }
                                var ids = currSelf.selectedHistoryList.join(',');
                                $.showLoading();
                                $.ajax({
                                    type: "post",
                                    url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!doDeleteZBBD.action",
                                    data: {
                                        mac: LocalUserInfo.GetUserInfo().Mac,
                                        userCode: LocalUserInfo.GetUserInfo().UserCode,
                                        zbId: ids,
                                        zbzbId: ""
                                    },
                                    dataType: "json",
                                    success: function (result) {
                                        var retData = ReturnData(result);
                                        if (retData.IsSuccess) {
                                        }
                                        currSelf.selectedHistoryList = [];
                                    },
                                    error: function (xhr, status, errorThrow) {
                                        console.error(status);
                                        $.alert("获取信息失败!");
                                        AudioUtils.Play(AudioUtils.ErrorMessage);
                                    },
                                    complete: function () {
                                        $.hideLoading();
                                    },
                                })
                            }
                        );
                    } else {
                        $.toptip("请选择您要删除的数据", "warning");
                        AudioUtils.Play(AudioUtils.SelectDeleted);
                    }
                },
                //历史列表编辑信息切换到绑定列表
                HistorySwitch: function (item) {
                    $(".tabbar>div>a").removeClass("active");//删除当前元素的样式
                    $(".tabbar>div>a").eq(1).addClass("active");//添加当前元素的样式
                    $('.content>div').hide();
                    $('.content>div').eq(1).show();
                    var currSelf = this;
                    currSelf.BindingList.PalletCode = item.ZBBD_ZBTMH;
                    currSelf.BindingID = item.GMES_PB_ZBBD_ID;
                    currSelf.WXNum = item.ZBBD_NXSL;
                    currSelf.BindingList.WordCode = item.ZBBD_DDHM;
                    if (item.detail && item.detail.length > 0) {
                        currSelf.CartonBarcode = item.detail;
                    }
                },
                //历史列表查询按钮
                HistoryListSearch: function () {
                    var currSelf = this;
                    $.showLoading();
                    $.ajax({
                        type: "post",
                        url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!getZBTMSj.action",
                        data: {
                            mac: LocalUserInfo.GetUserInfo().Mac,
                            userCode: LocalUserInfo.GetUserInfo().UserCode,
                            isComplete: '1',
                            ddhm: currSelf.HistoryOrderNumber,
                            barCode: currSelf.HistoryPalletNumber,
                            PageSize: currSelf.HistoryPageSize,
                            CurrPage: currSelf.HistoryCurrPage,
                        },
                        dataType: "json",
                        success: function (result) {
                            var retData = ReturnData(result);
                            if (retData.IsSuccess) {
                                currSelf.HistoryListData = retData.Data;
                                currSelf.HistoryTotalCount = retData.TotalCount;
                                for (var key in currSelf.HistoryListData) {
                                    currSelf.HistoryOrderNumber = "";
                                    currSelf.HistoryPalletNumber = "";
                                    return false;//返回false，不为空对象
                                }
                                currSelf.HistoryTotalCount = 1;
                                currSelf.HistoryOrderNumber = "";
                                currSelf.HistoryPalletNumber = "";
                                $.toptip("未找到相关信息", "error");
                                return true;//返回true，为空对象
                            }
                        },
                        error: function (xhr, status, errorThrow) {
                            console.error(status);
                            $.alert("获取信息失败!");
                            AudioUtils.Play(AudioUtils.ErrorMessage);
                        },
                        complete: function () {
                            $.hideLoading();
                        },
                    })
                },
                //历史列表数据获取
                GetHistoryListData: function () {
                    var currSelf = this;
                    currSelf.HistoryCurrPage = 1;
                    $("#hisorder").focus();
                    currSelf.HistoryOrderNumber = ""; //历史列表订单号码
                    currSelf.HistoryPalletNumber = "";//历史列表栈板条码                  
                    if (currSelf.BindingDataIsChang) {
                        $.modal({
                            title: "操作提示",
                            text: "离开绑定数据会丢失，请先保存！",
                            buttons: [
                                {
                                    text: "否", onClick: function () {
                                        $(".tabbar>div>a").removeClass("active");//删除当前元素的样式
                                        $(".tabbar>div>a").eq(2).addClass("active");//添加当前元素的样式
                                        $('.content>div').hide();
                                        $('.content>div').eq(2).show();
                                        currSelf.CartonBarcode = [];
                                        currSelf.BindingList.WordCode = "";
                                        currSelf.BindingDataIsChang = false;
                                        currSelf.tmyygzDynaBean = [];
                                        currSelf.BindingID = "";
                                    }
                                },
                                {
                                    text: "是", onClick: function () {
                                        $(".tabbar>div>a").removeClass("active");//删除当前元素的样式
                                        $(".tabbar>div>a").eq(1).addClass("active");//添加当前元素的样式
                                        $('.content>div').hide();
                                        $('.content>div').eq(1).show();

                                    }
                                },
                            ]
                        });
                    } else {
                        currSelf.CartonBarcode = [];
                        currSelf.BindingList.WordCode = "";
                        currSelf.tmyygzDynaBean = [];
                    }
                    $.showLoading();
                    $.ajax({
                        type: "post",
                        url: LocalConfig.SrvPath + "/jgmes/jgmesBarCodeAction!getZBTMSj.action",
                        data: {
                            mac: LocalUserInfo.GetUserInfo().Mac,
                            userCode: LocalUserInfo.GetUserInfo().UserCode,
                            isComplete: '1',
                            ddhm: currSelf.HistoryOrderNumber,
                            barCode: currSelf.HistoryPalletNumber,
                            PageSize: currSelf.HistoryPageSize,
                            CurrPage: currSelf.HistoryCurrPage,
                        },
                        dataType: "json",
                        success: function (result) {
                            var retData = ReturnData(result);
                            if (retData.IsSuccess) {
                                currSelf.HistoryListData = retData.Data

                                for (var index in currSelf.HistoryListData) {
                                    currSelf.HistoryListData[index].isShow = false;
                                    currSelf.HistoryTotalCount = retData.TotalCount;
                                    return false;//返回false，不为空对象
                                }
                                currSelf.HistoryTotalCount = 1;
                                $.toptip("未找到相关信息", "error");
                                return true;//返回true，为空对象
                            }

                        },
                        error: function (xhr, status, errorThrow) {
                            console.error(status);
                            $.alert("获取信息失败!");
                            AudioUtils.Play(AudioUtils.ErrorMessage);
                        },
                        complete: function () {
                            $.hideLoading();
                        },
                    })
                },
                //历史列表查询
                HistorySearch: function () {
                    var currSelf = this;
                    currSelf.HistoryCurrPage = 1;
                    currSelf.HistoryListSearch();
                },
                //历史列表上一页
                Historypre: function () {
                    var currSelf = this;
                    if (currSelf.HistoryCurrPage > 1) {
                        currSelf.HistoryCurrPage--;
                        currSelf.HistoryListSearch();
                    }
                },
                //历史列表下一页
                Historynext: function () {
                    var currSelf = this;
                    if (currSelf.HistoryCurrPage < Math.ceil(currSelf.HistoryTotalCount / currSelf.HistoryPageSize)) {
                        currSelf.HistoryCurrPage++;
                        currSelf.HistoryListSearch();
                    }
                }
            },
        })
    </script>
</body>

</html>